<?php
//debug($Dmdform);


if ($Dmdform['Dmdform']['is_new_user']==0):
    $table='User';
    $prefix=null;
else:
    $table='Dmdform';
    $prefix='user_';
endif;  ?>


<table class="showFields">
    <tr>
        <th><?php __('Name')  ?></th>
        <td><?php echo $Dmdform[$table][$prefix.'name'];  ?></td>
    </tr>
    <tr>
        <th><?php __('Surname')  ?></th>
        <td><?php echo $Dmdform[$table][$prefix.'surname'];  ?></td>
    </tr>
    <tr>
        <th><?php __('Status')  ?></th>
		<?php if($Dmdform[$table][$prefix.'status_id']>0) : ?>
        <td><?php echo $statuses[$Dmdform[$table][$prefix.'status_id']];  ?></td>
		<?php
		else:
			echo '<td></td>';
		endif;
		
		?>
    </tr>
    <tr>
        <th><?php __('Contract Dates')  ?></th>
        <td><?php echo 'from: '.$Dmdform[$table][$prefix.'contract_begin'].' to: '.$Dmdform[$table][$prefix.'contract_end'];  ?></td>
    </tr>
    <tr>
        <th><?php __('Id Code')  ?></th>
        <td><?php echo $Dmdform[$table][$prefix.'id_code'];  ?></td>
    </tr>
    <tr>
        <th><?php __('Id Erp')  ?></th>
        <td><?php echo $Dmdform[$table][$prefix.'id_erp'];  ?></td>
    </tr>
    <tr>
        <th><?php __('Id HR')  ?></th>
        <td><?php echo $Dmdform[$table][$prefix.'id_hr'];  ?></td>
    </tr>
    <tr>
        <th><?php __('Id Windows')  ?></th>
        <td><?php echo $Dmdform[$table][$prefix.'id_win'];  ?></td>
    </tr>

    <tr>
        <th><?php __('Replace')  ?></th>
        <?php if($Dmdform[$table][$prefix.'replace']>0):  ?>
        <td><?php echo $users[$Dmdform[$table][$prefix.'replace']];  ?></td>
        <?php else:  ?>
        <td></td>
        <?php endif;  ?>
    </tr>
</table>